package com.dlc.shop.live.common.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.dlc.shop.live.common.model.LiveRoom;
import com.dlc.shop.live.common.model.LiveRoomProd;
import com.dlc.shop.live.common.vo.LiveMsgItem;
import com.dlc.shop.live.common.vo.LiveRoomProdVO;

import java.util.List;

/**
 * 直播间商品
 * @author TRACK
 */
public interface LiveRoomProdService extends IService<LiveRoomProd> {

    /**
     * 保存直播间商品
     * @param liveRoom
     */
    void save(LiveRoom liveRoom);

    /**
     * 更新直播间商品
     * @param liveRoom
     */
    void update(LiveRoom liveRoom);

    /**
     * 删除直播间商品
     * @param roomId
     */
    void delete(Long roomId);

    /**
     * 获取直播间商品 im
     * @param roomId
     * @return
     */
    List<LiveRoomProdVO> listLiveRoomProd(Long roomId);

    /**
     * 更新商品讲解状态
     * @param roomId
     * @param prodId
     * @param explainStatus
     * @return
     */
    int updateExplainStatus(Long roomId, Long prodId, Integer explainStatus);

    /**
     * 获取直播间商品 admin
     * @param roomId
     * @return
     */
    List<LiveRoomProdVO> listLiveRoomProdInfo(Long roomId);

    /**
     * 组装商品信息返回
     * @param liveMsgItem
     * @return
     */
    LiveMsgItem handleLiveProd(LiveMsgItem liveMsgItem);
}
